package thread;

public class ThreadInfoDemo {
    public static void main(String[] args) {

        Thread t=new Thread("handle"){
            @Override
            public void run() {
                String name=this.getName();
                System.out.println(name);
               long id=  this.getId();
                System.out.println(id);
               // this.setPriority(1);
                int p=this.getPriority();
                System.out.println(p);
                try {
                    this.setDaemon(true);
                }catch (IllegalThreadStateException e){
                    System.out.println(e);
                }

                boolean boo= this.isInterrupted();
                System.out.println(boo);
                System.out.println(this.isAlive());
                System.out.println(this.isDaemon());
            }
        };
        t.start();
    }
}
